<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>PowerVR SDK</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
<table width="100%">
  <tr>
    <td width="33%">
      <p align="left">&nbsp;<a href="http://www.imgtec.com"><img border="0" src="IMGLogo.jpg" width="200" height="30"></a></p>
    </td>
    <td width="33%">
      <p align="center"><font color="#808080" face="Arial" size="2">PowerVR Software Development Kit</a></font></p>
    </td>
    <td width="34%">
      <p align="right"><a href="http://www.powervr.com"><img border="0" src="PVRlogo.jpg" width="200" height="27"></a></p>
    </td>
  </tr>
</table>
<hr>
</head><body>
<!-- Generated by Doxygen 1.3.6 -->
<div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a></div>
<h1>Light.h</h1><a href="Light_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <span class="comment">/******************************************************************************</span>
00002 <span class="comment"></span>
00003 <span class="comment"> @File         Light.h</span>
00004 <span class="comment"></span>
00005 <span class="comment"> @Title        Light</span>
00006 <span class="comment"></span>
00007 <span class="comment"> @Version      </span>
00008 <span class="comment"></span>
00009 <span class="comment"> @Copyright    Copyright (C)  Imagination Technologies Limited.</span>
00010 <span class="comment"></span>
00011 <span class="comment"> @Platform     Independent</span>
00012 <span class="comment"></span>
00013 <span class="comment"> @Description  Class to hold a Light with some convenient</span>
00014 <span class="comment">               constructors/functions/operators</span>
00015 <span class="comment"></span>
00016 <span class="comment">******************************************************************************/</span>
00017 
00018 <span class="preprocessor">#ifndef LIGHT_H</span>
00019 <span class="preprocessor"></span><span class="preprocessor">#define LIGHT_H</span>
00020 <span class="preprocessor"></span>
00021 <span class="comment">/******************************************************************************</span>
00022 <span class="comment">Includes</span>
00023 <span class="comment">******************************************************************************/</span>
00024 
00025 <span class="preprocessor">#include "PVRTools.h"</span>
00026 
00027 
00028 <span class="keyword">namespace </span>pvrengine
00029 {
00030     <span class="comment">/******************************************************************************</span>
00031 <span class="comment">    Enums</span>
00032 <span class="comment">    ******************************************************************************/</span>
00033     <span class="keyword">enum</span> <a class="code" href="namespacepvrengine.html#a95">ELightType</a>{
00034         <a class="code" href="namespacepvrengine.html#a95a0">eLightTypePoint</a>=0,
00035         <a class="code" href="namespacepvrengine.html#a95a1">eLightTypeDirectional</a>,
00036         <a class="code" href="namespacepvrengine.html#a95a2">eLightTypeSpot</a>,             <span class="comment">// not suppoted yet</span>
<a name="l00037"></a><a class="code" href="namespacepvrengine.html#a95">00037</a>         <a class="code" href="namespacepvrengine.html#a95a3">eLightTypePODPoint</a>,
00038         <a class="code" href="namespacepvrengine.html#a95a4">eLightTypePODDirectional</a>,
00039 <span class="comment">//      eLightPODSpot               // Not supported by POD yet</span>
00040         <a class="code" href="namespacepvrengine.html#a95a5">eNumLightTypes</a>
00041     };
00042 
00043     <span class="comment">/*!***************************************************************************</span>
00044 <span class="comment">    * @Class Light</span>
00045 <span class="comment">    * @Brief Class to hold a Light</span>
00046 <span class="comment">    * @Description Class to hold a Light</span>
00047 <span class="comment">    *****************************************************************************/</span>
00048     <span class="keyword">class </span>Light
00049     {
00050     <span class="keyword">public</span>:
00051         <span class="comment">/*!***************************************************************************</span>
00052 <span class="comment">        @Function           Light</span>
<a name="l00053"></a><a class="code" href="classpvrengine_1_1Light.html">00053</a> <span class="comment">        @Description        blank constructor.</span>
00054 <span class="comment">        *****************************************************************************/</span>
00055         <a class="code" href="classpvrengine_1_1Light.html#a0">Light</a>(){}
00056 
00057         <span class="comment">/*!***************************************************************************</span>
00058 <span class="comment">        @Function           Light</span>
00059 <span class="comment">        @Input              v3Colour - colour of light</span>
00060 <span class="comment">        @Input              eLightType - type of light</span>
<a name="l00061"></a><a class="code" href="classpvrengine_1_1Light.html#a0">00061</a> <span class="comment">        @Description        blank constructor.</span>
00062 <span class="comment">        *****************************************************************************/</span>
00063         <a class="code" href="classpvrengine_1_1Light.html#a0">Light</a>(<span class="keyword">const</span> PVRTVec3&amp; v3Colour, <span class="keyword">const</span> ELightType eLightType)
00064             :<a class="code" href="classpvrengine_1_1Light.html#p0">m_v3Colour</a>(v3Colour),<a class="code" href="classpvrengine_1_1Light.html#p1">m_eLightType</a>(eLightType){}
00065 
00066         <span class="comment">/*!***************************************************************************</span>
00067 <span class="comment">        @Function           Light</span>
00068 <span class="comment">        @Description        deconstructor.</span>
00069 <span class="comment">        *****************************************************************************/</span>
<a name="l00070"></a><a class="code" href="classpvrengine_1_1Light.html#a1">00070</a>         <span class="keyword">virtual</span> <a class="code" href="classpvrengine_1_1Light.html#a2">~Light</a>(){}
00071 
00072         <span class="comment">/*!***************************************************************************</span>
00073 <span class="comment">        @Function           shineLight</span>
00074 <span class="comment">        @Input              i32Index - index of the light to shine</span>
00075 <span class="comment">        @Description        sets up a hardware light (not functional in OpenGL)</span>
00076 <span class="comment">        *****************************************************************************/</span>
00077         <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1Light.html#a3">shineLight</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> i32Index)=0;
<a name="l00078"></a><a class="code" href="classpvrengine_1_1Light.html#a2">00078</a> 
00079         <span class="comment">/*!***************************************************************************</span>
00080 <span class="comment">        @Function           getColour</span>
00081 <span class="comment">        @Returns            the colour of the light</span>
00082 <span class="comment">        @Description        retrieves the colour of this light</span>
00083 <span class="comment">        *****************************************************************************/</span>
00084         PVRTVec3 <a class="code" href="classpvrengine_1_1Light.html#a4">getColour</a>(){<span class="keywordflow">return</span> <a class="code" href="classpvrengine_1_1Light.html#p0">m_v3Colour</a>;}
00085 
00086         <span class="comment">/*!***************************************************************************</span>
00087 <span class="comment">        @Function           getType</span>
00088 <span class="comment">        @Return             type of the light</span>
00089 <span class="comment">        @Description        gets the type of this light.</span>
00090 <span class="comment">        *****************************************************************************/</span>
00091         <a class="code" href="namespacepvrengine.html#a95">ELightType</a> <a class="code" href="classpvrengine_1_1Light.html#a5">getType</a>(){<span class="keywordflow">return</span> m_eLightType;}
00092 
00093     <span class="keyword">protected</span>:
<a name="l00094"></a><a class="code" href="classpvrengine_1_1Light.html#a4">00094</a>         PVRTVec3 <a class="code" href="classpvrengine_1_1Light.html#p0">m_v3Colour</a>;        
00095         <a class="code" href="namespacepvrengine.html#a95">ELightType</a> <a class="code" href="classpvrengine_1_1Light.html#p1">m_eLightType</a>;    
00097     };
00098 
00099     <span class="comment">/*!***************************************************************************</span>
00100 <span class="comment">    * @Class LightPoint</span>
00101 <span class="comment">    * @Brief Class to hold a Point Light</span>
<a name="l00102"></a><a class="code" href="classpvrengine_1_1Light.html#a5">00102</a> <span class="comment">    * @Description Class to hold a Point Light</span>
00103 <span class="comment">    *****************************************************************************/</span>
00104     <span class="keyword">class </span><a class="code" href="classpvrengine_1_1LightPoint.html">LightPoint</a> : <span class="keyword">public</span> <a class="code" href="classLight.html">Light</a>
<a name="l00105"></a><a class="code" href="classpvrengine_1_1Light.html#p0">00105</a>     {
<a name="l00106"></a><a class="code" href="classpvrengine_1_1Light.html#p1">00106</a>     <span class="keyword">public</span>:
00107         <span class="comment">/*!***************************************************************************</span>
00108 <span class="comment">        @Function           LightPoint</span>
00109 <span class="comment">        @Input              v3Position - position of the new light</span>
00110 <span class="comment">        @Input              v3Colour - colour of the light</span>
00111 <span class="comment">        @Description        Constructor.</span>
00112 <span class="comment">        *****************************************************************************/</span>
00113         <a class="code" href="classpvrengine_1_1LightPoint.html#a0">LightPoint</a>(<span class="keyword">const</span> PVRTVec3 v3Position, <span class="keyword">const</span> PVRTVec3 v3Colour);
00114 
00115         <span class="comment">/*!***************************************************************************</span>
<a name="l00116"></a><a class="code" href="classpvrengine_1_1LightPoint.html">00116</a> <span class="comment">        @Function           LightPoint</span>
00117 <span class="comment">        @Input              v4Position - position of the new light</span>
00118 <span class="comment">        @Input              v3Colour - colour of the light</span>
00119 <span class="comment">        @Description        Constructor.</span>
00120 <span class="comment">        *****************************************************************************/</span>
00121         <a class="code" href="classpvrengine_1_1LightPoint.html#a0">LightPoint</a>(<span class="keyword">const</span> PVRTVec4 v4Position, <span class="keyword">const</span> PVRTVec3 v3Colour);
00122 
00123         <span class="comment">/*!***************************************************************************</span>
00124 <span class="comment">        @Function           setPosition</span>
00125 <span class="comment">        @Input              v4Position - position of the light</span>
00126 <span class="comment">        @Description        Sets the position of the light.</span>
00127 <span class="comment">        *****************************************************************************/</span>
00128         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightPoint.html#a2">setPosition</a>(<span class="keyword">const</span> PVRTVec4 v4Position);
00129 
00130         <span class="comment">/*!***************************************************************************</span>
00131 <span class="comment">        @Function           setPosition</span>
00132 <span class="comment">        @Input              v3Position - position of the light</span>
00133 <span class="comment">        @Description        Sets the position of the light.</span>
00134 <span class="comment">        *****************************************************************************/</span>
00135         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightPoint.html#a2">setPosition</a>(<span class="keyword">const</span> PVRTVec3 v3Position);
00136 
00137         <span class="comment">/*!***************************************************************************</span>
00138 <span class="comment">        @Function           getPositionPVRTVec4</span>
00139 <span class="comment">        @Return             position of the light</span>
00140 <span class="comment">        @Description        gets the position of the light.</span>
00141 <span class="comment">        *****************************************************************************/</span>
00142         PVRTVec4 <a class="code" href="classpvrengine_1_1LightPoint.html#a4">getPositionPVRTVec4</a>(){<span class="keywordflow">return</span> <a class="code" href="classpvrengine_1_1LightPoint.html#p0">m_v4Position</a>;}
00143 
00144         <span class="comment">/*!***************************************************************************</span>
00145 <span class="comment">        @Function           getPositionPVRTVec3</span>
00146 <span class="comment">        @Return             position of the light</span>
00147 <span class="comment">        @Description        gets the position of the light.</span>
00148 <span class="comment">        *****************************************************************************/</span>
00149         PVRTVec3 <a class="code" href="classpvrengine_1_1LightPoint.html#a5">getPositionPVRTVec3</a>(){<span class="keywordflow">return</span> PVRTVec3(m_v4Position.x,m_v4Position.y,m_v4Position.z);}
00150 
00151         <span class="comment">/*!***************************************************************************</span>
00152 <span class="comment">        @Function           shineLight</span>
00153 <span class="comment">        @Input              u32Index - index of the light to shine</span>
00154 <span class="comment">        @Description        sets up a hardware light (not functional in OpenGL)</span>
00155 <span class="comment">        *****************************************************************************/</span>
00156         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightPoint.html#a6">shineLight</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> u32Index);
00157 
00158     <span class="keyword">protected</span>:
<a name="l00159"></a><a class="code" href="classpvrengine_1_1LightPoint.html#a4">00159</a>         PVRTVec4 <a class="code" href="classpvrengine_1_1LightPoint.html#p0">m_v4Position</a>;      
00160     };
00161 
00162     <span class="comment">/*!***************************************************************************</span>
00163 <span class="comment">    * @Class LightDirectional</span>
00164 <span class="comment">    * @Brief Class to hold a Directional Light</span>
00165 <span class="comment">    * @Description Class to hold a Directional Light</span>
00166 <span class="comment">    *****************************************************************************/</span>
<a name="l00167"></a><a class="code" href="classpvrengine_1_1LightPoint.html#a5">00167</a>     <span class="keyword">class </span><a class="code" href="classpvrengine_1_1LightDirectional.html">LightDirectional</a> : <span class="keyword">public</span> <a class="code" href="classpvrengine_1_1Light.html">Light</a>
00168     {
00169     <span class="keyword">public</span>:
00170         <span class="comment">/*!***************************************************************************</span>
00171 <span class="comment">        @Function           LightDirectional</span>
00172 <span class="comment">        @Input              v3Direction - direction of the new light</span>
00173 <span class="comment">        @Input              v3Colour - colour of the light</span>
00174 <span class="comment">        @Description        Constructor.</span>
00175 <span class="comment">        *****************************************************************************/</span>
00176         <a class="code" href="classpvrengine_1_1LightDirectional.html#a0">LightDirectional</a>(<span class="keyword">const</span> PVRTVec3 v3Direction, <span class="keyword">const</span> PVRTVec3 v3Colour);
00177 
<a name="l00178"></a><a class="code" href="classpvrengine_1_1LightPoint.html#p0">00178</a>         <span class="comment">/*!***************************************************************************</span>
00179 <span class="comment">        @Function           LightDirectional</span>
00180 <span class="comment">        @Input              v4Direction - direction of the new light</span>
00181 <span class="comment">        @Input              v3Colour - colour of the light</span>
00182 <span class="comment">        @Description        Constructor.</span>
00183 <span class="comment">        *****************************************************************************/</span>
00184         <a class="code" href="classpvrengine_1_1LightDirectional.html#a0">LightDirectional</a>(<span class="keyword">const</span> PVRTVec4 v4Direction, <span class="keyword">const</span> PVRTVec3 v3Colour);
00185 
00186         <span class="comment">/*!***************************************************************************</span>
<a name="l00187"></a><a class="code" href="classpvrengine_1_1LightDirectional.html">00187</a> <span class="comment">        @Function           setDirection</span>
00188 <span class="comment">        @Input              v3Direction - direction of the light</span>
00189 <span class="comment">        @Description        Sets the direction of the light.</span>
00190 <span class="comment">        *****************************************************************************/</span>
00191         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightDirectional.html#a2">setDirection</a>(<span class="keyword">const</span> PVRTVec3 v3Direction);
00192 
00193         <span class="comment">/*!***************************************************************************</span>
00194 <span class="comment">        @Function           setDirection</span>
00195 <span class="comment">        @Input              v4Direction - direction of the light</span>
00196 <span class="comment">        @Description        Sets the direction of the light.</span>
00197 <span class="comment">        *****************************************************************************/</span>
00198         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightDirectional.html#a2">setDirection</a>(<span class="keyword">const</span> PVRTVec4 v4Direction);
00199 
00200         <span class="comment">/*!***************************************************************************</span>
00201 <span class="comment">        @Function           getDirectionPVRTVec4</span>
00202 <span class="comment">        @Return             direction of the light</span>
00203 <span class="comment">        @Description        gets the direction of the light.</span>
00204 <span class="comment">        *****************************************************************************/</span>
00205         PVRTVec4 <a class="code" href="classpvrengine_1_1LightDirectional.html#a4">getDirectionPVRTVec4</a>(){<span class="keywordflow">return</span> <a class="code" href="classpvrengine_1_1LightDirectional.html#p0">m_v4Direction</a>;}
00206 
00207         <span class="comment">/*!***************************************************************************</span>
00208 <span class="comment">        @Function           getDirectionPVRTVec3</span>
00209 <span class="comment">        @Return             direction of the light</span>
00210 <span class="comment">        @Description        gets the direction of the light.</span>
00211 <span class="comment">        *****************************************************************************/</span>
00212         PVRTVec3 <a class="code" href="classpvrengine_1_1LightDirectional.html#a5">getDirectionPVRTVec3</a>(){<span class="keywordflow">return</span> PVRTVec3(m_v4Direction.x,m_v4Direction.y,m_v4Direction.z);}
00213 
00214         <span class="comment">/*!***************************************************************************</span>
00215 <span class="comment">        @Function           shineLight</span>
00216 <span class="comment">        @Input              u32Index - index of the light to shine</span>
00217 <span class="comment">        @Description        sets up a hardware light (not functional in OpenGL)</span>
00218 <span class="comment">        *****************************************************************************/</span>
00219         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightDirectional.html#a6">shineLight</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> u32Index);
00220 
00221     <span class="keyword">protected</span>:
00222         PVRTVec4 m_v4Direction;     
00223     };
00224 
00225 
00226     <span class="comment">/*!***************************************************************************</span>
00227 <span class="comment">    * @Class LightPODDirectional</span>
00228 <span class="comment">    * @Brief Class to hold a POD Directional Light</span>
00229 <span class="comment">    * @Description Class to hold a POD Directional Light</span>
<a name="l00230"></a><a class="code" href="classpvrengine_1_1LightDirectional.html#a4">00230</a> <span class="comment">    *****************************************************************************/</span>
00231     <span class="keyword">class </span><a class="code" href="classpvrengine_1_1LightPODDirectional.html">LightPODDirectional</a> : <span class="keyword">public</span> <a class="code" href="classpvrengine_1_1Light.html">Light</a>
00232     {
00233     <span class="keyword">public</span>:
00234         <span class="comment">/*!***************************************************************************</span>
00235 <span class="comment">        @Function           LightPODDirectional</span>
00236 <span class="comment">        @Input              pModelPOD - POD model from which light should come</span>
00237 <span class="comment">        @Input              iIndex - index into POD of this light</span>
<a name="l00238"></a><a class="code" href="classpvrengine_1_1LightDirectional.html#a5">00238</a> <span class="comment">        @Description        Constructor.</span>
00239 <span class="comment">        *****************************************************************************/</span>
00240         <a class="code" href="classpvrengine_1_1LightPODDirectional.html#a0">LightPODDirectional</a>(CPVRTModelPOD* pModelPOD, <span class="keyword">const</span> <span class="keywordtype">int</span> iIndex):
00241               <a class="code" href="classpvrengine_1_1Light.html">Light</a>(pModelPOD-&gt;pLight[iIndex].pfColour,<a class="code" href="namespacepvrengine.html#a95a4">eLightTypePODDirectional</a>),m_psModelPOD(pModelPOD),m_iIndex(iIndex){}
00242 
00243         <span class="comment">/*!***************************************************************************</span>
00244 <span class="comment">        @Function           getDirectionPVRTVec4</span>
00245 <span class="comment">        @Return             direction of the light</span>
00246 <span class="comment">        @Description        gets the direction of the light.</span>
00247 <span class="comment">        *****************************************************************************/</span>
00248         PVRTVec4 <a class="code" href="classpvrengine_1_1LightPODDirectional.html#a1">getDirectionPVRTVec4</a>(){<span class="keywordflow">return</span> m_psModelPOD-&gt;GetLightDirection(m_iIndex);}
<a name="l00249"></a><a class="code" href="classpvrengine_1_1LightDirectional.html#p0">00249</a> 
00250         <span class="comment">/*!***************************************************************************</span>
00251 <span class="comment">        @Function           getDirectionPVRTVec3</span>
00252 <span class="comment">        @Return             direction of the light</span>
00253 <span class="comment">        @Description        gets the direction of the light.</span>
00254 <span class="comment">        *****************************************************************************/</span>
00255         PVRTVec3 <a class="code" href="classpvrengine_1_1LightPODDirectional.html#a2">getDirectionPVRTVec3</a>(){<span class="keywordflow">return</span> m_psModelPOD-&gt;GetLightDirection(m_iIndex);}
00256 
00257         <span class="comment">/*!***************************************************************************</span>
00258 <span class="comment">        @Function           shineLight</span>
<a name="l00259"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html">00259</a> <span class="comment">        @Input              u32Index - index of the light to shine</span>
00260 <span class="comment">        @Description        sets up a hardware light (not functional in OpenGL)</span>
00261 <span class="comment">        *****************************************************************************/</span>
00262         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightPODDirectional.html#a3">shineLight</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> u32Index);
00263 
00264         <span class="comment">/*!***************************************************************************</span>
00265 <span class="comment">        @Function           isPODLight</span>
00266 <span class="comment">        @Return             whether light originated from a POD</span>
00267 <span class="comment">        @Description        determines whether light originated from a POD</span>
00268 <span class="comment">        *****************************************************************************/</span>
<a name="l00269"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#a0">00269</a>         CPVRTModelPOD* <a class="code" href="classpvrengine_1_1LightPODDirectional.html#a4">getModelPOD</a>(){<span class="keywordflow">return</span> <a class="code" href="classpvrengine_1_1LightPODDirectional.html#p0">m_psModelPOD</a>;}
00270 
00271     <span class="keyword">protected</span>:
00272         CPVRTModelPOD *m_psModelPOD;        
00273         <span class="keywordtype">int</span> m_iIndex;                       
00274     };
00275 
00276     <span class="comment">/*!***************************************************************************</span>
00277 <span class="comment">    * @Class LightPODPoint</span>
<a name="l00278"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#a1">00278</a> <span class="comment">    * @Brief Class to hold a POD Point Light</span>
00279 <span class="comment">    * @Description Class to hold a POD Point Light</span>
00280 <span class="comment">    *****************************************************************************/</span>
00281     <span class="keyword">class </span><a class="code" href="classpvrengine_1_1LightPODPoint.html">LightPODPoint</a> : <span class="keyword">public</span> <a class="code" href="classpvrengine_1_1Light.html">Light</a>
00282     {
00283     <span class="keyword">public</span>:
00284         <span class="comment">/*!***************************************************************************</span>
00285 <span class="comment">        @Function           LightPODPoint</span>
<a name="l00286"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#a2">00286</a> <span class="comment">        @Input              pModelPOD - POD model from which light should come</span>
00287 <span class="comment">        @Input              iIndex - index into POD of this light</span>
00288 <span class="comment">        @Description        Constructor.</span>
00289 <span class="comment">        *****************************************************************************/</span>
00290         <a class="code" href="classpvrengine_1_1LightPODPoint.html#a0">LightPODPoint</a>(CPVRTModelPOD* pModelPOD, <span class="keyword">const</span> <span class="keywordtype">int</span> iIndex):
00291           <a class="code" href="classpvrengine_1_1Light.html">Light</a>(pModelPOD-&gt;pLight[iIndex].pfColour,<a class="code" href="namespacepvrengine.html#a95a3">eLightTypePODPoint</a>),<a class="code" href="classpvrengine_1_1LightPODPoint.html#p0">m_psModelPOD</a>(pModelPOD),<a class="code" href="classpvrengine_1_1LightPODPoint.html#p1">m_iIndex</a>(iIndex){}
00292 
00293         <span class="comment">/*!***************************************************************************</span>
00294 <span class="comment">        @Function           getDirectionPVRTVec4</span>
00295 <span class="comment">        @Return             direction of the light</span>
00296 <span class="comment">        @Description        gets the direction of the light.</span>
00297 <span class="comment">        *****************************************************************************/</span>
00298         PVRTVec4 <a class="code" href="classpvrengine_1_1LightPODPoint.html#a1">getPositionPVRTVec4</a>(){<span class="keywordflow">return</span> m_psModelPOD-&gt;GetLightPosition(m_iIndex);}
00299 
00300         <span class="comment">/*!***************************************************************************</span>
00301 <span class="comment">        @Function           getDirectionPVRTVec3</span>
<a name="l00302"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#a4">00302</a> <span class="comment">        @Return             direction of the light</span>
00303 <span class="comment">        @Description        gets the direction of the light.</span>
00304 <span class="comment">        *****************************************************************************/</span>
<a name="l00305"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#p0">00305</a>         PVRTVec3 <a class="code" href="classpvrengine_1_1LightPODPoint.html#a2">getPositionPVRTVec3</a>(){<span class="keywordflow">return</span> <a class="code" href="classpvrengine_1_1LightPODPoint.html#p0">m_psModelPOD</a>-&gt;GetLightPosition(<a class="code" href="classpvrengine_1_1LightPODPoint.html#p1">m_iIndex</a>);}
<a name="l00306"></a><a class="code" href="classpvrengine_1_1LightPODDirectional.html#p1">00306</a> 
00307         <span class="comment">/*!***************************************************************************</span>
00308 <span class="comment">        @Function           shineLight</span>
00309 <span class="comment">        @Input              u32Index - index of the light to shine</span>
00310 <span class="comment">        @Description        sets up a hardware light (not functional in OpenGL)</span>
00311 <span class="comment">        *****************************************************************************/</span>
00312         <span class="keywordtype">void</span> <a class="code" href="classpvrengine_1_1LightPODPoint.html#a3">shineLight</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> u32Index);
00313 
00314         <span class="comment">/*!***************************************************************************</span>
<a name="l00315"></a><a class="code" href="classpvrengine_1_1LightPODPoint.html">00315</a> <span class="comment">        @Function           isPODLight</span>
00316 <span class="comment">        @Return             whether light originated from a POD</span>
00317 <span class="comment">        @Description        determines whether light originated from a POD</span>
00318 <span class="comment">        *****************************************************************************/</span>
00319         CPVRTModelPOD* <a class="code" href="classpvrengine_1_1LightPODPoint.html#a4">getModelPOD</a>(){<span class="keywordflow">return</span> m_psModelPOD;}
00320 
00321     <span class="keyword">protected</span>:
00322         CPVRTModelPOD *m_psModelPOD;        
00323         <span class="keywordtype">int</span> m_iIndex;                       
00324     };
<a name="l00325"></a><a class="code" href="classpvrengine_1_1LightPODPoint.html#a0">00325</a> 
00326 }
00327 
00328 <span class="preprocessor">#endif // LIGHT_H</span>
00329 <span class="preprocessor"></span>
00330 <span class="comment">/******************************************************************************</span>
00331 <span class="comment">End of file (Light.h)</span>
00332 <span class="comment">******************************************************************************/</span>
00333 
</pre></div><br>
<br>
<P align=left><FONT size=2><STRONG><A 
   href="http://www.imgtec.com/powervr/insider/legal/index.asp">Copyright</A> � 
   1999-2008, Imagination Technologies Ltd.</STRONG></FONT></P>
<hr>
<address style="align: left;"><small><FONT color=f0f>
Generated by <a href="http://www.doxygen.org/index.html">DOXYGEN</a> 1.3.6</small></address>
</body>
</html>
